﻿@model HeaderLinksModel
@using Nop.Web.Models.Common;
<script type="text/javascript">
    $(function () {
        $("#login").click(function () {
            $.fancybox.open({
                href: '/Login',
                type: 'iframe',
                padding: 5,
                width: 500,
                height: 200
            });
        });

        $("#Register").click(function () {
            $.fancybox.open({
                href: '/Register',
                type: 'iframe',
                padding: 5,
                width: 500
            });
        });
        $("#txtSearch").focus(function () {
            if ($("#txtSearch").val() == " 搜索   菜名/店铺") {
                $("#txtSearch").val("");
            }
        }).blur(function () {
            if (!$("#txtSearch").val()) {
                $("#txtSearch").val(" 搜索   菜名/店铺");
            }
        });
        $("#btnSearch").click(function () {
            //获取输入框中的值
            var txtSearch = $("#txtSearch").val();
            if (!txtSearch || txtSearch == " 搜索   菜名/店铺") {
                alert("请输入搜索条件");
            } else {
                window.location.href = "/Home/Search?strWhere=" + escape(txtSearch);
            }
        });
    });
</script>
<div class="ms_title_head">
    <div class="title_head_toolbar">
        <div class="title_toolbar_cont">
            <div class="title_logo">
                <a  href="@Url.RouteUrl("HomePage")">
                    <img alt="乐客网" src="@Url.Content("~/themes/Cnet/Content/image/Log.png")"></a></div>
            <ul class="title_toolbar_quick">
                <li>
                    @if (Model.DisplayAdminLink)
                    {
                        <a href="@Url.Content("~/admin")" class="t_register">@T("Account.Administration")</a>}HI，欢迎来到食街网！
                    请
                    @if (Model.IsAuthenticated)
                    {
                        <a href="@Url.RouteUrl("CustomerInfo")" class="t_register">@Model.CustomerEmailUsername</a>
                        <a href="@Url.RouteUrl("Logout")" class="t_login">@T("Account.Logout")</a>
                                                                     if (Model.AllowPrivateMessages)
                                                                     {
                        <a href="@Url.RouteUrl("PrivateMessages", new { tab = "" })" class="ico-inbox">@T("PrivateMessages.Inbox")</a>
                        @Model.UnreadPrivateMessages
                   if (!string.IsNullOrEmpty(Model.AlertMessage))
                   {<script type="text/javascript">
     $(document).ready(function () {
         displayPopupNotification('@(Model.AlertMessage)', 'success', false);
     });
</script>
                   }
                                                                     }
                    }
                    else
                    {
                        <a href="javascript:;" id="login">@T("Account.Login")</a>
                        <a href="javascript:;" id="Register">@T("Account.Register")</a>     
                    }
                    <b>
                        <img  alt="客服电话" src="@Url.Content("~/themes/Cnet/Content/image/phone.png")" />1351046073</b>
                    <b>
                        <img alt="投诉邮箱" src="@Url.Content("~/themes/Cnet/Content/image/email.png")" />投诉建议</b>
                </li>
                <li>
                    <div class="title_searchbar">
                        <form id="searchForm" action="">
                        <!-- focus时给input增加className：focus -->
                        <div class="title_txt_wrap">
                            <input type="text" id="txtSearch" value=" 搜索   菜名/店铺" autofocus="autofocus" x-webkit-speech=""
                                autocomplete="off" class="" /></div>
                        <div class="title_btn_search_wrap">
                            <input id="btnSearch" type="button" value="搜索" class="title_btn_search" /></div>
                        </form>
                    </div>
                </li>
            </ul>
        </div>
    </div>
</div>
<div class="home_nav_wrap">
    <div id="myDivFloat" class="home_nav" style="position: absolute; top: 0; filter: alpha(opacity=90);
        opacity: 0.9;">
        <div class="lnb_inner">
            <div class="nav_left">
                科技园[长虹大厦]</div>
            <div class="nav_mid">
                <div class="nav_items">
                    <ul id="top_ul">
                        <li class="curChn"><a target="_self" href="@Url.RouteUrl("HomePage")">首页</a></li>
                        <li id="Manufacturer"><a target="_self"  href="@Url.RouteUrl("ShopListRoute")">品牌店</a></li>
                        <li><a target="_blank" href="#">套餐系列</a></li>
                        <li><a target="_blank" href="#">10元快餐</a></li>
                        <li><a target="_blank" href="#">15元快餐</a></li>
                    </ul>
                </div>
            </div>
            <div class="nav_right">
                <span>
                    <img src="@Url.Content("~/themes/Cnet/Content/image/cart.png")"></span> <a href="@Url.RouteUrl("ShoppingCart")" class="ico-cart">@T("ShoppingCart")</a>
                <a href="@Url.RouteUrl("ShoppingCart")" class="cart-qty" id="myShoppingCartItems">(@Model.ShoppingCartItems)</a>
            </div>
        </div>
    </div>
</div>
<div style="height: 39px">
</div>
